<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<% include("/pages/includes/ueditor.html"){} %>
<script type="text/javascript" src="${BASE_PATH}static/js/jquery-1.11.2.min.js"></script>
<script type="text/javascript" src="${BASE_PATH}static/js/jquery.form.js"></script>
<script type="text/javascript">

var um;
$(document).ready(function(){
	um = UE.getEditor('editor',{
		initialFrameHeight:400  //初始化编辑器高度,默认320
	});
});

	var oper = {
		save:function(){
			var options={
					success:function(data){
						alert(data);
					}
			};
			$("#article_form").ajaxSubmit(options);
			
		}	
	};
</script>
<body>



<form id="article_form" action="${BASE_PATH}article/upload_file" method="post" enctype="multipart/form-data">
<table>
			<tr>
				<td width="15%">栏目</td>
				<td width="33%">
					<select name="model.folder_id"  valid="vselect" validname="栏目">
					${folderSelect }
					</select>
				</td>
				<td width="15%">名称</td>
				<td width="33%">
						<input  type="text" name="model.title" valid="vtext" validname="名称" />
				</td>
			</tr>
			
						<tr>
				<td>发布者</td>
				<td>
		
						<input class="form-control" type="text" name="model.publish_user"  />
	
				</td>
				<td>发布时间</td>
				<td>
						<input class="form-control" type="text" name="model.publish_time" >
				</td>
			</tr>
			
			
			<tr>
				<td>排序</td>
				<td>
						<input class="form-control" type="text" name="model.sort" 
						valid="vnum_y" validname="排序" />
				</td>
				<td>状态</td>
				<td>
					<label class="radio-inline">
					  <input type="radio" name="model.status" id="" value="2"  > 隐藏
					</label>
					<label class="radio-inline">
					  <input type="radio" name="model.status" id="" value="1" > 显示
					</label>
				</td>
			</tr>
			
			<tr>
				<td>是否评论</td>
				<td>
					<label class="radio-inline">
					  <input type="radio" name="model.is_comment" id="" value="1"  > 是
					</label>
					<label class="radio-inline">
					  <input type="radio" name="model.is_comment" id="" value="2"  > 否
					</label>
				</td>
				<td>是否推荐</td>
				<td>
					<label class="radio-inline">
					  <input type="radio" name="model.is_recommend" id="" value="1"   > 是
					</label>
					<label class="radio-inline">
					  <input type="radio" name="model.is_recommend" id="" value="2" > 否
					</label>
				</td>
			</tr>
			
		<tr>
				<td>开始时间</td>
				<td>
						<input type="text" name="model.start_time"  />
				</td>
				<td>结束时间</td>
				<td>
						<input type="text" name="model.end_time"  />
				</td>
		</tr>
		
		<tr>
				<td>附件</td>
				<td>
					<input type="file" accept="*/*" class="form-control" name="model.file_url" />
				</td>
		</tr>
			
</table>

		<div>
				<script id="editor" type="text/plain" name="model.content"
			style="width: 98%; height: 320px;"></script>
		</div>

<input type="button" value="submit" onclick="oper.save()">
</form>
</body>
</html>